<?php
/*
	关注扫码
*/
defined('BY_JYA') or exit('error');
list($params)=$arguments;
$id=$params['data']['id'];
if(!$id || !$params['data']['fromuser']){
	return false;
}
$this->model('model')->get_fee($id,$params['data']['fromuser']);
pdo_update('jy_poster_poster',array('follows +='=>1),array('id'=>$id,'uniacid'=>$_SESSION['uniacid']));
$poster=pdo_get('jy_poster_poster',array('id'=>$id,'uniacid'=>$_SESSION['uniacid']));
$jy_commission = $this->plugin_exists('jy_commission');
if($poster['fenxiao_level']){
	if($jy_commission){
		model('jy_commission/member')->set_parent($_SESSION['uid'],$params['data']['fromuser']);
	}
	$jy_newshopfee = $this->plugin_exists('jy_newshopfee');
	if($jy_newshopfee){
		model('jy_newshopfee/member')->set_parent($_SESSION['uid'],$params['data']['fromuser']);
	}
}
if($poster['fenxiao_set']){
	if($jy_commission){
		model('jy_commission/member')->checkmember($_SESSION['uid'],'',true);
	}
}
return true;